1. Technical Field
The present invention relates to an image compressing apparatus for compressing a color image, an image outputting apparatus including the image compressing apparatus, and an image compressing method.
2. Description of Related Art
In recent years, digital image processing systems have been remarkably developed, and establishment of digital image processing techniques have been advanced. For example, an image processing technique that reads an image such as a document recorded on a sheet of paper or the like using a scanner to generate a document file (image data) as electronic data is widely used in the fields of an electrophotographic or inkjet copier, an MFP (Multi-Function Printer), and the like. The document file generated by the image processing technique is used for various purposes by being stored in a database, or transmitted and received using facsimile communication or e-mail.
In general, image data read by a scanner (hereinafter referred to as a scanned image) has a large file size, and hence it is essential to compress the scanned image in order to efficiently store or transmit the scanned image.
As one compression technique for compressing an image at a high compression ratio, a compression technique on the basis of layer separation such as Mixed Raster Content (MRC) has been put into practical use. In the compression technique on the basis of layer separation, a foreground mask representing a text and/or a line art is generated from an image to be compressed, the image is separated into a foreground layer and a background layer on the basis of the generated foreground mask, and the foreground layer and the background layer are compressed by employing respective suitable compressing methods, whereby a highly compressed image is finally generated. At this point, the foreground layer is a layer of a foreground representing a text and/or a line art, and is generally compressed by employing a lossless compression technique such as JBIG (Joint Bi-level Image Experts Group), MMR (Modified Modified Readcode), LZW (Lempel Ziv Welch), or the like.
On the other hand, the background layer is a layer of a background representing an image content other than the text and/or the line art, and is generally compressed by employing a lossy compression technique such as JPEG (Joint Photographic Experts Group) or the like.
In a technique described in Japanese Patent Application Laid-Open No. 2003-18413, a color used in a text region is extracted from each text region in a color document image, an inclusive image including the text region in which the color is used is generated, MMR compression is performed on the inclusive image, and palette information and inclusive image information are added as a header. In addition, when a target text region has only one color, the MMR compression is performed on the target text region and, when the target text region has a plurality of colors, lossless compression is performed thereon. In the compression result, palette information and text information are added to a header. Further, in Japanese Patent Application Laid-Open No. 2003-18413, there is proposed a method in which the text region in the color document image is identified using the text information, an image having the identified text region filled with a specific color (corresponding to a page background image or a background layer) is generated, and JPEG compression is performed on the generated image.
In the compression by the lossy compression technique, the image quality of an image after being compressed is likely to be degraded when compared with the compression by the lossless compression technique. However, since the compression ratio is easily controlled in the lossy compression technique, in accordance with the use of a compressed image, the compression ratio can be increased with priority given to a small file size, or the compression ratio can be reduced with priority given to high image quality. On the other hand, since the compression ratio is difficult to control in the lossless compression technique, it is difficult to improve the compression ratio.